//
//  GSUser.h
//  AgileNYC
//
//  Created by German on 15.06.14.
//  Copyright (c) 2014 Softlegion. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <CoreData/CoreData.h>
#import <UIKit/UIKit.h>

@interface GSUser : NSManagedObject

@property (nonatomic, retain) NSString * city;
@property (nonatomic, retain) NSString * company;
@property (nonatomic, retain) NSString * deviceID;
@property (nonatomic, retain) NSNumber * deviceOS;
@property (nonatomic, retain) NSString * eMail;
@property (nonatomic, retain) NSString * firstName;
@property (nonatomic, retain) NSString * imageURL;

@property (nonatomic, retain) NSNumber * isChanged;
@property (nonatomic, retain) NSNumber * isMyProfile;
@property (nonatomic, retain) NSNumber * isRegistered;
@property (nonatomic, retain) NSNumber * isSynchronized;
@property (nonatomic, retain) NSNumber * isdeleted;
@property (nonatomic, retain) NSNumber * isTemp;

@property (nonatomic, retain) NSString * lastName;
@property (nonatomic, retain) NSString * memo;
@property (nonatomic, retain) NSNumber * mobileWorkingSystem;
@property (nonatomic, retain) NSDate * modifiedDate;
@property (nonatomic, retain) NSString * notes;
@property (nonatomic, retain) NSString * password;
@property (nonatomic, retain) NSString * phone;
@property (nonatomic, retain) NSString * sessionID;
@property (nonatomic, retain) NSString * socialID;
@property (nonatomic, retain) NSNumber * socialType;
@property (nonatomic, retain) NSString * state;
@property (nonatomic, retain) NSString * title;

@property (nonatomic, retain) NSString * facebookId;
@property (nonatomic, retain) NSString * facebookName;
@property (nonatomic, retain) NSString * googlePlusId;
@property (nonatomic, retain) NSString * googlePlusName;
@property (nonatomic, retain) NSString * linkedInId;
@property (nonatomic, retain) NSString * linkedInName;

@property (nonatomic, retain) NSNumber * userId;
@property (nonatomic, retain) NSString * webSite;
@property (nonatomic, retain) NSData * photo;

@property (nonatomic, retain) NSString * tokenAgile;
@property (nonatomic, retain) NSString * tokenFacebook;
@property (nonatomic, retain) NSString * tokenGooglePlus;
@property (nonatomic, retain) NSString * tokenLinkedIn;

@property (nonatomic, strong) UIImage * emptyImage;
@property (nonatomic, assign) BOOL imageWasLoaded;

-(void) completeWithServerResponse: (NSDictionary*) response;
-(NSDictionary*) returnDictionaryForAgileServer;

-(void) setPhotoAsImage:(UIImage*) photo;
-(UIImage*) getPhotoAsImage;

-(NSString*) fullName;
-(NSString*) location;
-(NSString*) companyAndPosition;
-(NSString*) allUserData; //For search purpose

@end
